****************************************************
******Leader visits and Nuclear pursuit*************
************************Lee*************************
****************Created: Jun 2025*******************
****************************************************

* Analysis run using Stata17 *
Version 17

* Required packages *
ssc install relogit
ssc install psmatch2
ssc install pstest

* Set working directory * 
cd "./data" 
use "Replication_main.dta", clear



*** Main results ***
xtset cowcc year

** Table 1: The determinants of superpower leader visit **
logit vis_us l.us_ally l.conflict l.gdpcap_ln l.industry l.nuke_latency l.majorpower l.demo l.npt_rati if year<=1991, cluster(cowcc) //Model1
logit vis_rus l.soviet_ally l.conflict l.gdpcap_ln l.industry l.nuke_latency l.majorpower l.demo l.npt_rati if year<=1991, cluster(cowcc) //Model2

** Table 3: The effect of superpower leader visit on nuclear pursuit **
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model1
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.conflict==1 & year<=1991, cluster(cowcc) //Model2 
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 i.year if year<=1991, cluster(cowcc) //Model3
relogit nukepursue_JG l_vis_us l_vis_rus l_nukeally l_gdpcap_ln l_industry l_demo l_majorpower l_conflict l_npt_rati l_npt_eff l_nca l_senstech l_JG1 l_JG2 l_JG3 if year<=1991, cluster(cowcc) //Model4

** Table 4: The effect of US leader visit on alliance status **
logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==1 & year<=1991, cluster(cowcc) //Model1
logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==0 & year<=1991, cluster(cowcc) //Model2
logit nukepursue_JG l.vis_rus l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.soviet_ally==1 & year<=1991, cluster(cowcc) //Model3
logit nukepursue_JG l.vis_rus l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.soviet_ally==0 & year<=1991, cluster(cowcc) //Model4


*** Appendices *** 

** Appendix 1: Descriptive statistics **
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model1

sum if e(sample)==1


** Appendix 2: The effect of superpower leader visit on nuclear pursuit (Country fixed effect) **
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 i.cowcc if year<=1991, cluster(cowcc) 


** Appendix 3: The effect of US leader visit on alliance status (Interaction model) **

* (a) Regression table of interaction model *
logit nukepursue_JG l.vis_us l.us_ally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model1
logit nukepursue_JG i.l.vis_us##i.l.us_ally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model2

* (b) Marginal effectss of interaction model *
margins, dydx(l.vis_us) at(l.us_ally=(0 1)) level(90) atmeans 
marginsplot, ///
	recast(scatter) ///
	title("") ///
    xtitle("US allies") ///
	xscale(range(-0.2 1.2)) ///
	xlabel(1 "US non-allies" 0 "US allies", angle(0)) ///
	ytitle("Marginal Effect of US leader visit (dy/dx)") ///
	ylabel(, angle(0)) /// 
	yline(0, lwidth(thin) lpattern(shortdash)) /// 
	legend(off)
	
** Appendix4 : The effect of superpower leader visit on nuclear pursuit (Singh and Way dataset) **
logit nukepursue_SW l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.SW1 l.SW2 l.SW3 if year<=1991, cluster(cowcc) //Model1
logit nukepursue_SW l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.SW1 l.SW2 l.SW3 if l.conflict==1 & year<=1991, cluster(cowcc) //Model2 
logit nukepursue_SW l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.SW1 l.SW2 l.SW3 i.year if year<=1991, cluster(cowcc) //Model3
logit nukepursue_SW l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.SW1 l.SW2 l.SW3 if l.us_ally==1 & year<=1991, cluster(cowcc) //Model4
logit nukepursue_SW l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.SW1 l.SW2 l.SW3 if l.us_ally==0 & year<=1991, cluster(cowcc) //Model5

** Appendix 5: The effect of superpower leader visit on nuclear pursuit (Smith and Malis dataset) **
logit nukepursue_JG l.vis_us_smith l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model1
logit nukepursue_JG l.vis_us_smith l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.conflict==1 & year<=1991, cluster(cowcc) //Model2 
logit nukepursue_JG l.vis_us_smith l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 i.year if year<=1991, cluster(cowcc) //Model3
logit nukepursue_JG l.vis_us_smith l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==1 & year<=1991, cluster(cowcc) //Model4
logit nukepursue_JG l.vis_us_smith l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==0 & year<=1991, cluster(cowcc) //Model5

** Appendix 6: The effect of superpower leader visit on nuclear pursuit (using propensity score matching) **

* (a) Regression table with propensity score matching *

psmatch2 vis_us us_ally conflict gdpcap_ln industry nuke_latency majorpower demo npt_rati, outcome(nukepursue_JG) neighbor(1)
logit nukepursue_JG l.vis_us l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 [iweight=_pscore] if year<=1991, cluster(cowcc) //Model1

psmatch2 vis_rus soviet_ally conflict gdpcap_ln industry nuke_latency majorpower demo npt_rati, outcome(nukepursue_JG) neighbor(1)
logit nukepursue_JG l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 [iweight=_pscore] if year<=1991, cluster(cowcc) //Model2

psmatch2 vis_us us_ally conflict gdpcap_ln industry nuke_latency majorpower demo npt_rati, outcome(nukepursue_JG) neighbor(1)
logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 [iweight=_pscore] if l.us_ally==1 & year<=1991 , cluster(cowcc) //Model3

logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 [iweight=_pscore] if l.us_ally==0 & year<=1991, cluster(cowcc) //Model4

* (b) Results of balance test *
psmatch2 vis_us us_ally conflict gdpcap_ln industry nuke_latency majorpower demo npt_rati, outcome(nukepursue_JG) neighbor(1)
pstest us_ally conflict gdpcap_ln industry nuke_latency majorpower demo npt_rati, outcome(nukepursue_JG) 

** Appendix 7: Determinants of leader visit using the interaction term of US Ally and Nuclear pursuit ongoing variable **
logit vis_us l.us_ally##l.nukepursue_ongoing l.majorpower l.conflict l.gdpcap_ln l.industry l.nuke_latency l.nca l.senstech l.demo l.npt_eff l.npt_rati if year<=1991, cluster(cowcc) 

** Appendix 8: The effect of superpower leader visit on nuclear pursuit onset **
reg nukepursue_onset l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati l.npt_eff l.nca l.senstech l.OS1 l.OS2 l.OS3 if year<=1991, cluster(cowcc)

** Appendix 9: The effect of superpower leader visit on nuclear pursuit (using rivalry and US nuclear deployment variable) **
logit nukepursue_JG l.vis_us l.vis_rus l.usnuc l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.rivalry l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if year<=1991, cluster(cowcc) //Model1
logit nukepursue_JG l.vis_us l.vis_rus l.usnuc l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.rivalry l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.rivalry==1 & year<=1991, cluster(cowcc) //Model2 
logit nukepursue_JG l.vis_us l.vis_rus l.usnuc l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.rivalry l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 i.year if year<=1991, cluster(cowcc) //Model3
logit nukepursue_JG l.vis_us l.usnuc l.gdpcap_ln l.industry l.demo l.majorpower l.rivalry l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==1 & year<=1991, cluster(cowcc) //Model4
logit nukepursue_JG l.vis_us l.usnuc l.gdpcap_ln l.industry l.demo l.majorpower l.rivalry l.npt_rati l.npt_eff l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==0 & year<=1991, cluster(cowcc) //Model5

** Appendix 10: The effect of superpower leader visit on nuclear pursuit (including post cold war) **
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati_expand l.npt_eff_expand l.nca l.senstech l.JG1 l.JG2 l.JG3, cluster(cowcc) //Model1
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati_expand l.npt_eff_expand l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.conflict==1, cluster(cowcc) //Model2 
logit nukepursue_JG l.vis_us l.vis_rus l.nukeally l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati_expand l.nca l.senstech l.JG1 l.JG2 l.JG3 i.year, cluster(cowcc) //Model3
logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati_expand l.npt_eff_expand l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==1, cluster(cowcc) //Model4 
logit nukepursue_JG l.vis_us l.gdpcap_ln l.industry l.demo l.majorpower l.conflict l.npt_rati_expand l.npt_eff_expand l.nca l.senstech l.JG1 l.JG2 l.JG3 if l.us_ally==0, cluster(cowcc) //Model5











 

